package com.apache.poi.word.config.policy;

import com.deepoove.poi.XWPFTemplate;
import com.deepoove.poi.policy.RenderPolicy;
import com.deepoove.poi.template.ElementTemplate;
import com.deepoove.poi.template.run.RunTemplate;
import org.apache.poi.xwpf.usermodel.XWPFRun;

/**
 * @Author: HUANG GY.
 * @Date: 2022/2/10 15:48
 * @Description: com.apache.poi.word.config.policy
 */
public class BreakPageRenderPolicy implements RenderPolicy {

    @Override
    public void render(ElementTemplate eleTemplate, Object data, XWPFTemplate template) {

        template.getXWPFDocument().createParagraph().setPageBreak(Boolean.TRUE);

    }

}
